{extend name="public/base" /}
{block name="main-container"}
<article class="main-user">
    <div class="layui-tab">
        <ul class="layui-tab-title">
            <li class="layui-this">成员列表</li>
            <li>添加成员</li>
        </ul>
        <div class="layui-tab-content">
            <div class="layui-tab-item layui-show">
                <table class="layui-table">
                    <tr>
                        <td>用户编号</td>
                        <td>用户账号</td>
                        <td>真实姓名</td>
                        <td>最后登录IP</td>
                        <td>最后登录时间</td>
                        <td>用户状态</td>
                        <td>用户操作</td>
                    </tr>
                    {volist name='members' id='member'}
                    <tr>
                        <td>{$member.id}</td>
                        <td>{$member.username}</td>
                        <td>{$member.realname}</td>
                        <td>{$member.last_login_ip}</td>
                        <td>{$member.last_login_time}</td>
                        <td class="layui-form">
                            <input type="checkbox" lay-skin="switch" lay-filter="status" lay-text="ON|OFF" data-id="{$member.id}"  value="1" {eq name="member.status" value="1"} checked{/eq}>
                        </td>
                        <td class="textalign">
                            <a href="javascript:member.edit('{$member.id}');" class="layui-btn layui-btn-small btn-success">
                                编辑
                            </a>
                            <a href="javascript:member.delete('{$member.id}');"  class="layui-btn layui-btn-small btn-danger">
                                删除
                            </a>
                        </td>
                    </tr>
                    {/volist}
                </table>
                <div class="fr mt20">
                    总记录数：{$members->total()} {$members->render()}
                </div>
            </div>
            <div class="layui-tab-item">
                {include file="member/create" /}
            </div>
        </div>
    </div>
</article>
{/block}
